Documentation for Users
1.0.2
Perception Toolbox for Virtual Reality (PTVR) Manual
|
In some special cases, PTVR provides simplified interactions, i.e. ways to avoid creating standard interactions relying on explicit interactions between Events and Callbacks.
These simplified interactions are rare in PTVR: they are only meant to reduce code length in very special cases as presented below.
When you want to control the duration of a scene, you can do it by using the special class SimplifiedTimerScene (instead of the class Scene plus an interaction) with one line of code as shown below:
This simplified code above does the same as the standard code below :
Python file | Description |
---|---|
...\PTVR_Researchers\Python_Scripts\Demos\Scenes\ 1_one_scene_w_simplified_duration.py | Creates a scene whose duration is controlled by using the SimplifiedTimerScene class. |
...\PTVR_Researchers\Python_Scripts\Demos\Scenes\ 2_one_scene_w_NON_simplified_duration.py | Creates a scene whose duration is controlled by using a standard interaction between an Event and an Callback. |
...\PTVR_Researchers\Python_Scripts\Demos\Objects\ 3_rotation_animated_about_one_axis.py | Animated rotation of a cube with a succession of scenes each being controlled in duration by the SimplifiedTimerScene class. |